# Tanım: QML ve JavaScript dilleri için sınıflar
# URL: http://qt-project.org/
# Paketçi: Cihan_Alkan 
# Gerekler: qt5-xmlpatterns python
# Grup: geliştirme

isim=qt5-declarative
surum=5.11.0
devir=1
_pkgfqn="${isim/5-/}-everywhere-src-${surum}"

kaynak=(http://download.qt.io/official_releases/qt/${surum%.*}/${surum}/submodules/${_pkgfqn}.tar.xz)

derle() {
  mkdir -p build
  cd build

  qmake ../${_pkgfqn}
  make
  make INSTALL_ROOT="$PKG" install

  # Symlinks for backwards compatibility
  for b in "$PKG"/usr/bin/*; do
    ln -s /usr/bin/$(basename $b) "$PKG"/usr/bin/$(basename $b)-qt5
  done

  # Drop QMAKE_PRL_BUILD_DIR because reference the build dir
  find "$PKG/usr/lib" -type f -name '*.prl' \
    -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d' {} \;

  install -d "$PKG"/usr/share/licenses
  ln -s /usr/share/licenses/qt5-base "$PKG"/usr/share/licenses/${isim}
}

